// Copyright 2022 a.o.smith ALL Rights Reserved
package com.liuxinlong.enums;

/**
 * 论坛状态枚举
 *
 * @author liuxinlong@hotwater.com.cn
 * @version 1.0.0
 * @since 2022-06-15
 */
public enum BarStatusEnum {
    PENDING(0,"未审核"),
    APPROVED(1,"审核通过"),
    JPEG(2,"审核不通过"),
    JPG(3,"删除");

    private int value;

    private String name;

    BarStatusEnum(int value, String name) {
        this.value = value;
        this.name = name;
    }

    public int getValue() {
        return value;
    }

    public String getName() {
        return name;
    }

    public static String getNameByValue(int value) {
        BarStatusEnum arrObj[] = BarStatusEnum.values();
        for (BarStatusEnum obj : arrObj) {
            if (value == obj.getValue()) {
                return obj.getName();
            }
        }
        return " ";
    }
}
